package guoanmaker.operator.business.repository;

import java.util.List;

import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;

import guoanmaker.operator.business.model.OperatorRole;


public interface OperatorRoleRepository extends  JpaRepository<OperatorRole, String>, JpaSpecificationExecutor<OperatorRole> {

	List<OperatorRole> findAll();
	
    @Query("select r from OperatorRole r where r.rolename=:rolename")	
	public OperatorRole  selectByRolename(@Param("rolename") String rolename);
    @Query("select r from OperatorRole r where r.id=:id")	
    public OperatorRole  selectById(@Param("id") String id);
    
	
}
